import { createRouter, createWebHashHistory, createWebHistory } from 'vue-router'
import About from '../pages/About.vue'
import Home from '../pages/Home.vue'

// 配置映射关系
const routes = [
  {
    path: '/',
    redirect: '/home',
  },
  {
    path: '/home',
    component: Home,
  },
  {
    path: '/about',
    component: About,
  },
]
const router = createRouter({
  routes,
  history: createWebHistory(),
})
export default router
